package com.design.state;

public class Context {

    private State state;


    public void push(){
        state.last(this);
        System.out.println(state.getState());
    }

    public void pull(){
        state.next(this);
        System.out.println(state.getState());
    }

    public State getState() {
        return state;
    }

    public void setState(State state) {
        this.state = state;
    }
}
